package cn.iocoder.yudao.module.crossborder.platform.enums;

import cn.iocoder.yudao.framework.common.exception.ErrorCode;

/**
 * CrossBorder 错误码枚举类
 *
 * crossborder 系统，使用 1-030-000-000 段
 */
public interface ErrorCodeConstants {

    // ========== 平台管理 1-030-001-000 ==========
    ErrorCode PLATFORM_NOT_EXISTS = new ErrorCode(1_030_001_000, "跨境电商平台不存在");
    ErrorCode PLATFORM_CODE_DUPLICATE = new ErrorCode(1_030_001_001, "平台代码已经存在");
    ErrorCode PLATFORM_TYPE_DUPLICATE = new ErrorCode(1_030_001_002, "平台类型已经存在");

    // ========== 店铺管理 1-030-002-000 ==========
    ErrorCode STORE_NOT_EXISTS = new ErrorCode(1_030_002_000, "店铺不存在");
    ErrorCode STORE_NAME_DUPLICATE = new ErrorCode(1_030_002_001, "店铺名称已经存在");
    ErrorCode STORE_PLATFORM_ID_DUPLICATE = new ErrorCode(1_030_002_002, "平台店铺ID已经存在");
    ErrorCode PLATFORM_STORE_NOT_EXISTS = new ErrorCode(1_030_002_003, "平台店铺不存在");

    // ========== 授权管理 1-030-003-000 ==========
    ErrorCode AUTH_NOT_EXISTS = new ErrorCode(1_030_003_000, "授权信息不存在");
    ErrorCode AUTH_EXPIRED = new ErrorCode(1_030_003_001, "授权已过期");
    ErrorCode AUTH_INVALID = new ErrorCode(1_030_003_002, "授权无效");
    ErrorCode PLATFORM_AUTH_NOT_EXISTS = new ErrorCode(1_030_003_003, "平台授权信息不存在");

    // ========== 同步管理 1-030-004-000 ==========
    ErrorCode SYNC_TASK_NOT_EXISTS = new ErrorCode(1_030_004_000, "同步任务不存在");
    ErrorCode SYNC_TASK_RUNNING = new ErrorCode(1_030_004_001, "同步任务正在运行中");
    ErrorCode PLATFORM_SYNC_TASK_NOT_EXISTS = new ErrorCode(1_030_004_002, "平台同步任务不存在");

    // ========== 配置管理 1-030-005-000 ==========
    ErrorCode CONFIG_NOT_EXISTS = new ErrorCode(1_030_005_000, "配置不存在");
    ErrorCode CONFIG_KEY_DUPLICATE = new ErrorCode(1_030_005_001, "配置键已经存在");

    // ========== 平台配置管理 1-030-005-100 ==========
    ErrorCode PLATFORM_CONFIG_NOT_EXISTS = new ErrorCode(1_030_005_100, "平台配置不存在");
    ErrorCode PLATFORM_CONFIG_DISABLED = new ErrorCode(1_030_005_101, "平台配置已禁用");
    ErrorCode PLATFORM_API_KEY_INVALID = new ErrorCode(1_030_005_102, "平台API密钥无效");
    ErrorCode PLATFORM_CONNECTION_FAILED = new ErrorCode(1_030_005_103, "平台连接失败");
    ErrorCode PLATFORM_API_CONFIG_NOT_EXISTS = new ErrorCode(1_030_005_104, "平台API配置不存在");

    // ========== 映射管理 1-030-006-000 ==========
    ErrorCode MAPPING_NOT_EXISTS = new ErrorCode(1_030_006_000, "映射配置不存在");
    ErrorCode MAPPING_DUPLICATE = new ErrorCode(1_030_006_001, "映射配置已经存在");
    ErrorCode PLATFORM_MAPPING_NOT_EXISTS = new ErrorCode(1_030_006_002, "平台映射配置不存在");
    ErrorCode PLATFORM_CATEGORY_MAPPING_NOT_EXISTS = new ErrorCode(1_030_006_003, "平台分类映射配置不存在");
    ErrorCode PLATFORM_ORDER_MAPPING_NOT_EXISTS = new ErrorCode(1_030_006_004, "平台订单映射配置不存在");
    ErrorCode PLATFORM_PRODUCT_MAPPING_NOT_EXISTS = new ErrorCode(1_030_006_005, "平台商品映射配置不存在");

    // ========== Webhook管理 1-030-007-000 ==========
    ErrorCode WEBHOOK_NOT_EXISTS = new ErrorCode(1_030_007_000, "Webhook配置不存在");
    ErrorCode WEBHOOK_URL_DUPLICATE = new ErrorCode(1_030_007_001, "Webhook URL已经存在");
    ErrorCode PLATFORM_WEBHOOK_NOT_EXISTS = new ErrorCode(1_030_007_002, "平台Webhook配置不存在");

    // ========== 日志管理 1-030-008-000 ==========
    ErrorCode LOG_NOT_EXISTS = new ErrorCode(1_030_008_000, "日志不存在");
    ErrorCode PLATFORM_API_LOG_NOT_EXISTS = new ErrorCode(1_030_008_001, "平台API日志不存在");
    ErrorCode PLATFORM_WEBHOOK_LOG_NOT_EXISTS = new ErrorCode(1_030_008_002, "平台Webhook日志不存在");

    // ========== 费率配置管理 1-030-009-000 ==========
    ErrorCode PLATFORM_FEE_CONFIG_NOT_EXISTS = new ErrorCode(1_030_009_000, "平台费率配置不存在");

}
